package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.common.annotation.AutoFill;
import com.ruoyi.common.enums.AutoFillType;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.DispatchMultiPeriodAnalysisRecordsMapper;
import com.ruoyi.system.domain.DispatchMultiPeriodAnalysisRecords;
import com.ruoyi.system.service.IDispatchMultiPeriodAnalysisRecordsService;

/**
 * 多时段分析记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-03-02
 */
@Service
public class DispatchMultiPeriodAnalysisRecordsServiceImpl implements IDispatchMultiPeriodAnalysisRecordsService 
{
    @Autowired
    private DispatchMultiPeriodAnalysisRecordsMapper dispatchMultiPeriodAnalysisRecordsMapper;

    /**
     * 查询多时段分析记录
     * 
     * @param multiPeriodAnalysisRecordsId 多时段分析记录主键
     * @return 多时段分析记录
     */
    @Override
    public DispatchMultiPeriodAnalysisRecords selectDispatchMultiPeriodAnalysisRecordsByMultiPeriodAnalysisRecordsId(Long multiPeriodAnalysisRecordsId)
    {
        return dispatchMultiPeriodAnalysisRecordsMapper.selectDispatchMultiPeriodAnalysisRecordsByMultiPeriodAnalysisRecordsId(multiPeriodAnalysisRecordsId);
    }

    /**
     * 查询多时段分析记录列表
     * 
     * @param dispatchMultiPeriodAnalysisRecords 多时段分析记录
     * @return 多时段分析记录
     */
    @Override
    public List<DispatchMultiPeriodAnalysisRecords> selectDispatchMultiPeriodAnalysisRecordsList(DispatchMultiPeriodAnalysisRecords dispatchMultiPeriodAnalysisRecords)
    {
        return dispatchMultiPeriodAnalysisRecordsMapper.selectDispatchMultiPeriodAnalysisRecordsList(dispatchMultiPeriodAnalysisRecords);
    }

    /**
     * 新增多时段分析记录
     * 
     * @param dispatchMultiPeriodAnalysisRecords 多时段分析记录
     * @return 结果
     */
    @AutoFill(operation = AutoFillType.INSERT)
    @Override
    public int insertDispatchMultiPeriodAnalysisRecords(DispatchMultiPeriodAnalysisRecords dispatchMultiPeriodAnalysisRecords)
    {
        return dispatchMultiPeriodAnalysisRecordsMapper.insertDispatchMultiPeriodAnalysisRecords(dispatchMultiPeriodAnalysisRecords);
    }

    /**
     * 修改多时段分析记录
     * 
     * @param dispatchMultiPeriodAnalysisRecords 多时段分析记录
     * @return 结果
     */
    @AutoFill(operation = AutoFillType.UPDATE)
    @Override
    public int updateDispatchMultiPeriodAnalysisRecords(DispatchMultiPeriodAnalysisRecords dispatchMultiPeriodAnalysisRecords)
    {
        return dispatchMultiPeriodAnalysisRecordsMapper.updateDispatchMultiPeriodAnalysisRecords(dispatchMultiPeriodAnalysisRecords);
    }

    /**
     * 批量删除多时段分析记录
     * 
     * @param multiPeriodAnalysisRecordsIds 需要删除的多时段分析记录主键
     * @return 结果
     */
    @Override
    public int deleteDispatchMultiPeriodAnalysisRecordsByMultiPeriodAnalysisRecordsIds(Long[] multiPeriodAnalysisRecordsIds)
    {
        return dispatchMultiPeriodAnalysisRecordsMapper.deleteDispatchMultiPeriodAnalysisRecordsByMultiPeriodAnalysisRecordsIds(multiPeriodAnalysisRecordsIds);
    }

    /**
     * 删除多时段分析记录信息
     * 
     * @param multiPeriodAnalysisRecordsId 多时段分析记录主键
     * @return 结果
     */
    @Override
    public int deleteDispatchMultiPeriodAnalysisRecordsByMultiPeriodAnalysisRecordsId(Long multiPeriodAnalysisRecordsId)
    {
        return dispatchMultiPeriodAnalysisRecordsMapper.deleteDispatchMultiPeriodAnalysisRecordsByMultiPeriodAnalysisRecordsId(multiPeriodAnalysisRecordsId);
    }
}
